3.2 \(\int (d+e x)^3 (a+b \tan ^{-1}(c x)) \, dx\)

Optimal. Leaf size=144 \[ \frac{(d+e x)^4 \left (a+b \tan ^{-1}(c x)\right )}{4 e}-\frac{b e x \left (6 c^2 d^2-e^2\right )}{4 c^3}-\frac{b \left (-6 c^2 d^2 e^2+c^4 d^4+e^4\right ) \tan ^{-1}(c x)}{4 c^4 e}-\frac{b d (c d-e) (c d+e) \log \left (c^2 x^2+1\right )}{2 c^3}-\frac{b d e^2 x^2}{2 c}-\frac{b e^3 x^3}{12 c} \]

[Out]

-(b*e*(6*c^2*d^2 - e^2)*x)/(4*c^3) - (b*d*e^2*x^2)/(2*c) - (b*e^3*x^3)/(12*c) - (b*(c^4*d^4 - 6*c^2*d^2*e^2 +
e^4)*ArcTan[c*x])/(4*c^4*e) + ((d + e*x)^4*(a + b*ArcTan[c*x]))/(4*e) - (b*d*(c*d - e)*(c*d + e)*Log[1 + c^2*x
^2])/(2*c^3)

________________________________________________________________________________________

Rubi [A]  time = 0.122858, antiderivative size = 144, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 5, integrand size = 16, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.312, Rules used = {4862, 702, 635, 203, 260} \[ \frac{(d+e x)^4 \left (a+b \tan ^{-1}(c x)\right )}{4 e}-\frac{b e x \left (6 c^2 d^2-e^2\right )}{4 c^3}-\frac{b \left (-6 c^2 d^2 e^2+c^4 d^4+e^4\right ) \tan ^{-1}(c x)}{4 c^4 e}-\frac{b d (c d-e) (c d+e) \log \left (c^2 x^2+1\right )}{2 c^3}-\frac{b d e^2 x^2}{2 c}-\frac{b e^3 x^3}{12 c} \]

Antiderivative was successfully verified.

[In]

Int[(d + e*x)^3*(a + b*ArcTan[c*x]),x]

[Out]

-(b*e*(6*c^2*d^2 - e^2)*x)/(4*c^3) - (b*d*e^2*x^2)/(2*c) - (b*e^3*x^3)/(12*c) - (b*(c^4*d^4 - 6*c^2*d^2*e^2 +
e^4)*ArcTan[c*x])/(4*c^4*e) + ((d + e*x)^4*(a + b*ArcTan[c*x]))/(4*e) - (b*d*(c*d - e)*(c*d + e)*Log[1 + c^2*x
^2])/(2*c^3)

Rule 4862

Int[((a_.) + ArcTan[(c_.)*(x_)]*(b_.))*((d_) + (e_.)*(x_))^(q_.), x_Symbol] :> Simp[((d + e*x)^(q + 1)*(a + b*
ArcTan[c*x]))/(e*(q + 1)), x] - Dist[(b*c)/(e*(q + 1)), Int[(d + e*x)^(q + 1)/(1 + c^2*x^2), x], x] /; FreeQ[{
a, b, c, d, e, q}, x] && NeQ[q, -1]

Rule 702

Int[((d_) + (e_.)*(x_))^(m_)/((a_) + (c_.)*(x_)^2), x_Symbol] :> Int[PolynomialDivide[(d + e*x)^m, a + c*x^2,
x], x] /; FreeQ[{a, c, d, e}, x] && NeQ[c*d^2 + a*e^2, 0] && IGtQ[m, 1] && (NeQ[d, 0] || GtQ[m, 2])

Rule 635

Int[((d_) + (e_.)*(x_))/((a_) + (c_.)*(x_)^2), x_Symbol] :> Dist[d, Int[1/(a + c*x^2), x], x] + Dist[e, Int[x/
(a + c*x^2), x], x] /; FreeQ[{a, c, d, e}, x] &&  !NiceSqrtQ[-(a*c)]

Rule 203

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1*ArcTan[(Rt[b, 2]*x)/Rt[a, 2]])/(Rt[a, 2]*Rt[b, 2]), x] /;
 FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a, 0] || GtQ[b, 0])

Rule 260

Int[(x_)^(m_.)/((a_) + (b_.)*(x_)^(n_)), x_Symbol] :> Simp[Log[RemoveContent[a + b*x^n, x]]/(b*n), x] /; FreeQ
[{a, b, m, n}, x] && EqQ[m, n - 1]

Rubi steps

\begin{align*} \int (d+e x)^3 \left (a+b \tan ^{-1}(c x)\right ) \, dx &=\frac{(d+e x)^4 \left (a+b \tan ^{-1}(c x)\right )}{4 e}-\frac{(b c) \int \frac{(d+e x)^4}{1+c^2 x^2} \, dx}{4 e}\\ &=\frac{(d+e x)^4 \left (a+b \tan ^{-1}(c x)\right )}{4 e}-\frac{(b c) \int \left (\frac{e^2 \left (6 c^2 d^2-e^2\right )}{c^4}+\frac{4 d e^3 x}{c^2}+\frac{e^4 x^2}{c^2}+\frac{c^4 d^4-6 c^2 d^2 e^2+e^4+4 c^2 d (c d-e) e (c d+e) x}{c^4 \left (1+c^2 x^2\right )}\right ) \, dx}{4 e}\\ &=-\frac{b e \left (6 c^2 d^2-e^2\right ) x}{4 c^3}-\frac{b d e^2 x^2}{2 c}-\frac{b e^3 x^3}{12 c}+\frac{(d+e x)^4 \left (a+b \tan ^{-1}(c x)\right )}{4 e}-\frac{b \int \frac{c^4 d^4-6 c^2 d^2 e^2+e^4+4 c^2 d (c d-e) e (c d+e) x}{1+c^2 x^2} \, dx}{4 c^3 e}\\ &=-\frac{b e \left (6 c^2 d^2-e^2\right ) x}{4 c^3}-\frac{b d e^2 x^2}{2 c}-\frac{b e^3 x^3}{12 c}+\frac{(d+e x)^4 \left (a+b \tan ^{-1}(c x)\right )}{4 e}-\frac{(b d (c d-e) (c d+e)) \int \frac{x}{1+c^2 x^2} \, dx}{c}-\frac{\left (b \left (c^4 d^4-6 c^2 d^2 e^2+e^4\right )\right ) \int \frac{1}{1+c^2 x^2} \, dx}{4 c^3 e}\\ &=-\frac{b e \left (6 c^2 d^2-e^2\right ) x}{4 c^3}-\frac{b d e^2 x^2}{2 c}-\frac{b e^3 x^3}{12 c}-\frac{b \left (c^4 d^4-6 c^2 d^2 e^2+e^4\right ) \tan ^{-1}(c x)}{4 c^4 e}+\frac{(d+e x)^4 \left (a+b \tan ^{-1}(c x)\right )}{4 e}-\frac{b d (c d-e) (c d+e) \log \left (1+c^2 x^2\right )}{2 c^3}\\ \end{align*}

Mathematica [A]  time = 0.452377, size = 218, normalized size = 1.51 \[ \frac{(d+e x)^4 \left (a+b \tan ^{-1}(c x)\right )-\frac{b c \left (2 \sqrt{-c^2} e^2 x \left (c^2 \left (18 d^2+6 d e x+e^2 x^2\right )-3 e^2\right )-3 \left (-2 c^2 d^2 e \left (2 \sqrt{-c^2} d+3 e\right )+c^4 d^4+e^3 \left (4 \sqrt{-c^2} d+e\right )\right ) \log \left (1-\sqrt{-c^2} x\right )+3 \left (2 c^2 d^2 e \left (2 \sqrt{-c^2} d-3 e\right )+c^4 d^4+e^3 \left (e-4 \sqrt{-c^2} d\right )\right ) \log \left (\sqrt{-c^2} x+1\right )\right )}{6 \left (-c^2\right )^{5/2}}}{4 e} \]

Antiderivative was successfully verified.

[In]

Integrate[(d + e*x)^3*(a + b*ArcTan[c*x]),x]

[Out]

((d + e*x)^4*(a + b*ArcTan[c*x]) - (b*c*(2*Sqrt[-c^2]*e^2*x*(-3*e^2 + c^2*(18*d^2 + 6*d*e*x + e^2*x^2)) - 3*(c
^4*d^4 + e^3*(4*Sqrt[-c^2]*d + e) - 2*c^2*d^2*e*(2*Sqrt[-c^2]*d + 3*e))*Log[1 - Sqrt[-c^2]*x] + 3*(c^4*d^4 + 2
*c^2*d^2*(2*Sqrt[-c^2]*d - 3*e)*e + e^3*(-4*Sqrt[-c^2]*d + e))*Log[1 + Sqrt[-c^2]*x]))/(6*(-c^2)^(5/2)))/(4*e)

________________________________________________________________________________________

Maple [A]  time = 0.028, size = 207, normalized size = 1.4 \begin{align*}{\frac{a{e}^{3}{x}^{4}}{4}}+a{e}^{2}{x}^{3}d+{\frac{3\,ae{x}^{2}{d}^{2}}{2}}+ax{d}^{3}+{\frac{a{d}^{4}}{4\,e}}+{\frac{b{e}^{3}\arctan \left ( cx \right ){x}^{4}}{4}}+b{e}^{2}\arctan \left ( cx \right ){x}^{3}d+{\frac{3\,be\arctan \left ( cx \right ){x}^{2}{d}^{2}}{2}}+b\arctan \left ( cx \right ) x{d}^{3}-{\frac{b{e}^{3}{x}^{3}}{12\,c}}-{\frac{b{e}^{2}d{x}^{2}}{2\,c}}-{\frac{3\,be{d}^{2}x}{2\,c}}+{\frac{b{e}^{3}x}{4\,{c}^{3}}}-{\frac{b\ln \left ({c}^{2}{x}^{2}+1 \right ){d}^{3}}{2\,c}}+{\frac{b{e}^{2}\ln \left ({c}^{2}{x}^{2}+1 \right ) d}{2\,{c}^{3}}}+{\frac{3\,\arctan \left ( cx \right ) be{d}^{2}}{2\,{c}^{2}}}-{\frac{b{e}^{3}\arctan \left ( cx \right ) }{4\,{c}^{4}}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((e*x+d)^3*(a+b*arctan(c*x)),x)

[Out]

1/4*a*e^3*x^4+a*e^2*x^3*d+3/2*a*e*x^2*d^2+a*x*d^3+1/4*a/e*d^4+1/4*b*e^3*arctan(c*x)*x^4+b*e^2*arctan(c*x)*x^3*
d+3/2*b*e*arctan(c*x)*x^2*d^2+b*arctan(c*x)*x*d^3-1/12*b*e^3*x^3/c-1/2*b*d*e^2*x^2/c-3/2*b/c*e*d^2*x+1/4*b/c^3
*e^3*x-1/2/c*b*ln(c^2*x^2+1)*d^3+1/2/c^3*b*e^2*ln(c^2*x^2+1)*d+3/2/c^2*b*e*arctan(c*x)*d^2-1/4/c^4*b*e^3*arcta
n(c*x)

________________________________________________________________________________________

Maxima [A]  time = 1.46532, size = 251, normalized size = 1.74 \begin{align*} \frac{1}{4} \, a e^{3} x^{4} + a d e^{2} x^{3} + \frac{3}{2} \, a d^{2} e x^{2} + \frac{3}{2} \,{\left (x^{2} \arctan \left (c x\right ) - c{\left (\frac{x}{c^{2}} - \frac{\arctan \left (c x\right )}{c^{3}}\right )}\right )} b d^{2} e + \frac{1}{2} \,{\left (2 \, x^{3} \arctan \left (c x\right ) - c{\left (\frac{x^{2}}{c^{2}} - \frac{\log \left (c^{2} x^{2} + 1\right )}{c^{4}}\right )}\right )} b d e^{2} + \frac{1}{12} \,{\left (3 \, x^{4} \arctan \left (c x\right ) - c{\left (\frac{c^{2} x^{3} - 3 \, x}{c^{4}} + \frac{3 \, \arctan \left (c x\right )}{c^{5}}\right )}\right )} b e^{3} + a d^{3} x + \frac{{\left (2 \, c x \arctan \left (c x\right ) - \log \left (c^{2} x^{2} + 1\right )\right )} b d^{3}}{2 \, c} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)^3*(a+b*arctan(c*x)),x, algorithm="maxima")

[Out]

1/4*a*e^3*x^4 + a*d*e^2*x^3 + 3/2*a*d^2*e*x^2 + 3/2*(x^2*arctan(c*x) - c*(x/c^2 - arctan(c*x)/c^3))*b*d^2*e +
1/2*(2*x^3*arctan(c*x) - c*(x^2/c^2 - log(c^2*x^2 + 1)/c^4))*b*d*e^2 + 1/12*(3*x^4*arctan(c*x) - c*((c^2*x^3 -
 3*x)/c^4 + 3*arctan(c*x)/c^5))*b*e^3 + a*d^3*x + 1/2*(2*c*x*arctan(c*x) - log(c^2*x^2 + 1))*b*d^3/c

________________________________________________________________________________________

Fricas [A]  time = 2.32974, size = 410, normalized size = 2.85 \begin{align*} \frac{3 \, a c^{4} e^{3} x^{4} +{\left (12 \, a c^{4} d e^{2} - b c^{3} e^{3}\right )} x^{3} + 6 \,{\left (3 \, a c^{4} d^{2} e - b c^{3} d e^{2}\right )} x^{2} + 3 \,{\left (4 \, a c^{4} d^{3} - 6 \, b c^{3} d^{2} e + b c e^{3}\right )} x + 3 \,{\left (b c^{4} e^{3} x^{4} + 4 \, b c^{4} d e^{2} x^{3} + 6 \, b c^{4} d^{2} e x^{2} + 4 \, b c^{4} d^{3} x + 6 \, b c^{2} d^{2} e - b e^{3}\right )} \arctan \left (c x\right ) - 6 \,{\left (b c^{3} d^{3} - b c d e^{2}\right )} \log \left (c^{2} x^{2} + 1\right )}{12 \, c^{4}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)^3*(a+b*arctan(c*x)),x, algorithm="fricas")

[Out]

1/12*(3*a*c^4*e^3*x^4 + (12*a*c^4*d*e^2 - b*c^3*e^3)*x^3 + 6*(3*a*c^4*d^2*e - b*c^3*d*e^2)*x^2 + 3*(4*a*c^4*d^
3 - 6*b*c^3*d^2*e + b*c*e^3)*x + 3*(b*c^4*e^3*x^4 + 4*b*c^4*d*e^2*x^3 + 6*b*c^4*d^2*e*x^2 + 4*b*c^4*d^3*x + 6*
b*c^2*d^2*e - b*e^3)*arctan(c*x) - 6*(b*c^3*d^3 - b*c*d*e^2)*log(c^2*x^2 + 1))/c^4

________________________________________________________________________________________

Sympy [A]  time = 2.21886, size = 262, normalized size = 1.82 \begin{align*} \begin{cases} a d^{3} x + \frac{3 a d^{2} e x^{2}}{2} + a d e^{2} x^{3} + \frac{a e^{3} x^{4}}{4} + b d^{3} x \operatorname{atan}{\left (c x \right )} + \frac{3 b d^{2} e x^{2} \operatorname{atan}{\left (c x \right )}}{2} + b d e^{2} x^{3} \operatorname{atan}{\left (c x \right )} + \frac{b e^{3} x^{4} \operatorname{atan}{\left (c x \right )}}{4} - \frac{b d^{3} \log{\left (x^{2} + \frac{1}{c^{2}} \right )}}{2 c} - \frac{3 b d^{2} e x}{2 c} - \frac{b d e^{2} x^{2}}{2 c} - \frac{b e^{3} x^{3}}{12 c} + \frac{3 b d^{2} e \operatorname{atan}{\left (c x \right )}}{2 c^{2}} + \frac{b d e^{2} \log{\left (x^{2} + \frac{1}{c^{2}} \right )}}{2 c^{3}} + \frac{b e^{3} x}{4 c^{3}} - \frac{b e^{3} \operatorname{atan}{\left (c x \right )}}{4 c^{4}} & \text{for}\: c \neq 0 \\a \left (d^{3} x + \frac{3 d^{2} e x^{2}}{2} + d e^{2} x^{3} + \frac{e^{3} x^{4}}{4}\right ) & \text{otherwise} \end{cases} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)**3*(a+b*atan(c*x)),x)

[Out]

Piecewise((a*d**3*x + 3*a*d**2*e*x**2/2 + a*d*e**2*x**3 + a*e**3*x**4/4 + b*d**3*x*atan(c*x) + 3*b*d**2*e*x**2
*atan(c*x)/2 + b*d*e**2*x**3*atan(c*x) + b*e**3*x**4*atan(c*x)/4 - b*d**3*log(x**2 + c**(-2))/(2*c) - 3*b*d**2
*e*x/(2*c) - b*d*e**2*x**2/(2*c) - b*e**3*x**3/(12*c) + 3*b*d**2*e*atan(c*x)/(2*c**2) + b*d*e**2*log(x**2 + c*
*(-2))/(2*c**3) + b*e**3*x/(4*c**3) - b*e**3*atan(c*x)/(4*c**4), Ne(c, 0)), (a*(d**3*x + 3*d**2*e*x**2/2 + d*e
**2*x**3 + e**3*x**4/4), True))

________________________________________________________________________________________

Giac [A]  time = 1.2029, size = 316, normalized size = 2.19 \begin{align*} \frac{3 \, b c^{4} x^{4} \arctan \left (c x\right ) e^{3} + 12 \, b c^{4} d x^{3} \arctan \left (c x\right ) e^{2} + 18 \, b c^{4} d^{2} x^{2} \arctan \left (c x\right ) e + 12 \, b c^{4} d^{3} x \arctan \left (c x\right ) + 3 \, a c^{4} x^{4} e^{3} + 12 \, a c^{4} d x^{3} e^{2} + 18 \, a c^{4} d^{2} x^{2} e + 12 \, a c^{4} d^{3} x - 18 \, \pi b c^{2} d^{2} e \mathrm{sgn}\left (c\right ) \mathrm{sgn}\left (x\right ) - b c^{3} x^{3} e^{3} - 6 \, b c^{3} d x^{2} e^{2} - 18 \, b c^{3} d^{2} x e - 6 \, b c^{3} d^{3} \log \left (c^{2} x^{2} + 1\right ) + 18 \, b c^{2} d^{2} \arctan \left (c x\right ) e + 6 \, b c d e^{2} \log \left (c^{2} x^{2} + 1\right ) + 3 \, b c x e^{3} - 3 \, b \arctan \left (c x\right ) e^{3}}{12 \, c^{4}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((e*x+d)^3*(a+b*arctan(c*x)),x, algorithm="giac")

[Out]

1/12*(3*b*c^4*x^4*arctan(c*x)*e^3 + 12*b*c^4*d*x^3*arctan(c*x)*e^2 + 18*b*c^4*d^2*x^2*arctan(c*x)*e + 12*b*c^4
*d^3*x*arctan(c*x) + 3*a*c^4*x^4*e^3 + 12*a*c^4*d*x^3*e^2 + 18*a*c^4*d^2*x^2*e + 12*a*c^4*d^3*x - 18*pi*b*c^2*
d^2*e*sgn(c)*sgn(x) - b*c^3*x^3*e^3 - 6*b*c^3*d*x^2*e^2 - 18*b*c^3*d^2*x*e - 6*b*c^3*d^3*log(c^2*x^2 + 1) + 18
*b*c^2*d^2*arctan(c*x)*e + 6*b*c*d*e^2*log(c^2*x^2 + 1) + 3*b*c*x*e^3 - 3*b*arctan(c*x)*e^3)/c^4